<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title>用户编码demo</title>
		<style type="text/css">
			
		</style>
		<script src="../jquery-1.8.3.min.js"></script>
		<script>
			function fun(){
				$.ajax({
					type: "POST",
					url:"http://localhost:8091/getAll",
					success:function(data){
						console.log(data);
						$('#01').text(data[0].id);
						$('#02').text(data[0].name);
						$('#03').text(data[0].age);
						$('#04').text(data[0].sex);
						$('#11').text(data[1].id);
						$('#12').text(data[1].name);
						$('#13').text(data[1].age);
						$('#14').text(data[1].sex);
						$('#21').text(data[2].id);
						$('#22').text(data[2].name);
						$('#23').text(data[2].age);
						$('#24').text(data[2].sex);
					}
				})
			}
		</script>
	</head>
	<body>
		<table border="1px" align="center" width="80%">
			<tr>
				<td colspan="4" align="center" onclick="fun();"><h1>用户的列表</h1></td>
			</tr>
			<tr>
				<td align="center">编号</td>
				<td align="center">姓名</td>
				<td align="center">年龄</td>
				<td align="center">性别</td>
			</tr>
			<tr>
				<td id="01" align="center"></td>
				<td id="02"align="center"></td>
				<td id="03"align="center"></td>
				<td id="04"align="center"></td>
			</tr>
			<tr>
				<td id="11" align="center"></td>
				<td id="12"align="center"></td>
				<td id="13"align="center"></td>
				<td id="14"align="center"></td>
			</tr>
			<tr>
				<td id="21" align="center"></td>
				<td id="22"align="center"></td>
				<td id="23"align="center"></td>
				<td id="24"align="center"></td>
			</tr>
		</table>
	</body>
</html>
